﻿using System;

namespace BankTransfer.Bank.Infrastructure.Repository.DO
{
    public class AccountDO
    {
        public long Id { get; set; }
        public long UserId { get; set; }
        public string AccountNumber { get; set; }
        public string Currency { get; set; }
        public decimal AvailableAmount { get; set; }

        #region DO里不应该包含行为

        internal string GetCurrency()
        {
            return Currency;
        }

        /// <summary>
        /// 可用金额
        /// </summary>
        /// <returns></returns>
        internal decimal GetAvailable()
        {
            return AvailableAmount;
        }

        internal void SetAvailable(decimal newSource)
        {
            AvailableAmount = newSource;
        }

        /// <summary>
        /// 每日限制
        /// </summary>
        /// <returns></returns>
        internal decimal GetDailyLimit()
        {
            throw new NotImplementedException();
        }

        #endregion DO里不应该包含行为
    }
}